from django.shortcuts import render, HttpResponse

# Create your views here.

def book_detail_query_string(request):
    book_id = request.GET.get('id')
    name = request.GET.get('name')
    return HttpResponse(f"你查找的book_id是：{book_id}, "
                        f"图书名称是：{name}")

def book_detail_path(request, book_id):
    return HttpResponse(f"你的图书ID是{book_id}")

# path函数
def book_str(request, book_id):
    return  HttpResponse(f"你查看的图示ID是：{book_id}")

def book_slug(request, book_id):
    return  HttpResponse(f"你查看的图示ID是：{book_id}")

def book_path(request, book_id):
    return  HttpResponse(f"你查看的图示ID是：{book_id}")
